package cn.itcast.config;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

public class QuotConfig {
    public static Properties config = new Properties();
    //加载配置文件
    static {
        //通过类加载器进行获取
        InputStream rs = QuotConfig.class.getClassLoader().getResourceAsStream("config.properties");
        try {
            config.load(rs);
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

    public static void main(String[] args) {
        System.out.println(config.getProperty("close.time"));
    }


}
